<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
    <head>
        <meta charset="UTF-8">
        <!-- 移动端设置不缩放 -->
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <title>归档</title>
        <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css">
        <link rel="stylesheet" th:href="@{/css/common.css}">
        <link rel="stylesheet" th:href="@{/css/archive.css}">
    </head>
    <body>
        <!-- navbar -->
        <nav th:replace="_fragment::navbar(3)"></nav>
        
        <!-- content -->
        <div>
            <div class="container">
                <div class="row m-container">
                    <div class="col-xs-8 col-xs-offset-2">
                        <!-- top -->
                        <div class="archive-title">
                            <h2 class="inline">归档</h2>
                        </div>
                        <!-- archive -->
                        <div th:each="monthMapEntry: ${yearWithMonthMap}" class="archive">
                            <h2 th:text="${monthMapEntry.key}"></h2>
                            <div th:each="entry: ${monthMapEntry.value}" class="list-group">
                                <h3 th:text="${entry.key}"></h3>
                                <a th:href="@{/detail(id=${minBlog.id})}" th:each="minBlog: ${entry.value}" class="list-group-item">
                                    <span class="glyphicon glyphicon-arrow-right" aria-hidden="true"></span>
                                    <h3 class="blog-title" th:text="${minBlog.title}"></h3>
                                    <span class="label-data" th:text="${#dates.format(minBlog.createTime, 'MM月dd日')}"></span>
                                    <span class="label label-default pull-right hidden-xs hidden-sm" th:text="${minBlog.flag == 0 ? '原创' : '转载'}"></span>
                                </a>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- footer -->
        <footer th:replace="_fragment::footer"></footer>

        <script src="https://cdn.staticfile.org/jquery/3.2.0/jquery.min.js"></script>
        <script src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js" ></script>
        <script src="https://eqcn.ajz.miesnfu.com/wp-content/plugins/wp-3d-pony/live2dw/lib/L2Dwidget.min.js"></script>
        <script th:src="@{/js/common.js}"></script>
    </body>
</html>